package org.lanqiao.dao;

import org.lanqiao.entity.Gift;
import org.lanqiao.entity.WxuserGift;
import org.lanqiao.mapper.GiftMapper;
import org.lanqiao.mapper.WxuserGiftMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class WxuserGiftDao {

    @Autowired
    WxuserGiftMapper wxuserGiftMapper;

    @Autowired
    GiftMapper giftMapper;

    public void addGift(WxuserGift wxuserGift){
        wxuserGiftMapper.addGift(wxuserGift);

    }

    /*
     * 查询所有礼物信息
     * */
    public List<Gift> selectAllGift(){
        List<Gift> gifts = giftMapper.selectAllGift();
        return gifts;
    }
}
